3.162 \(\int \frac {\tan (d (a+b \log (c x^n)))}{x} \, dx\)

Optimal. Leaf size=26 \[ -\frac {\log \left (\cos \left (a d+b d \log \left (c x^n\right )\right )\right )}{b d n} \]

[Out]

-ln(cos(a*d+b*d*ln(c*x^n)))/b/d/n

________________________________________________________________________________________

Rubi [A]  time = 0.02, antiderivative size = 26, normalized size of antiderivative = 1.00, number of steps used = 2, number of rules used = 1, integrand size = 17, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.059, Rules used = {3475} \[ -\frac {\log \left (\cos \left (a d+b d \log \left (c x^n\right )\right )\right )}{b d n} \]

Antiderivative was successfully verified.

[In]

Int[Tan[d*(a + b*Log[c*x^n])]/x,x]

[Out]

-(Log[Cos[a*d + b*d*Log[c*x^n]]]/(b*d*n))

Rule 3475

Int[tan[(c_.) + (d_.)*(x_)], x_Symbol] :> -Simp[Log[RemoveContent[Cos[c + d*x], x]]/d, x] /; FreeQ[{c, d}, x]

Rubi steps

\begin {align*} \int \frac {\tan \left (d \left (a+b \log \left (c x^n\right )\right )\right )}{x} \, dx &=\frac {\operatorname {Subst}\left (\int \tan (d (a+b x)) \, dx,x,\log \left (c x^n\right )\right )}{n}\\ &=-\frac {\log \left (\cos \left (a d+b d \log \left (c x^n\right )\right )\right )}{b d n}\\ \end {align*}

________________________________________________________________________________________

Mathematica [A]  time = 0.05, size = 25, normalized size = 0.96 \[ -\frac {\log \left (\cos \left (d \left (a+b \log \left (c x^n\right )\right )\right )\right )}{b d n} \]

Antiderivative was successfully verified.

[In]

Integrate[Tan[d*(a + b*Log[c*x^n])]/x,x]

[Out]

-(Log[Cos[d*(a + b*Log[c*x^n])]]/(b*d*n))

________________________________________________________________________________________

fricas [A]  time = 0.45, size = 35, normalized size = 1.35 \[ -\frac {\log \left (\frac {1}{2} \, \cos \left (2 \, b d n \log \relax (x) + 2 \, b d \log \relax (c) + 2 \, a d\right ) + \frac {1}{2}\right )}{2 \, b d n} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(tan(d*(a+b*log(c*x^n)))/x,x, algorithm="fricas")

[Out]

-1/2*log(1/2*cos(2*b*d*n*log(x) + 2*b*d*log(c) + 2*a*d) + 1/2)/(b*d*n)

________________________________________________________________________________________

giac [F(-1)]  time = 0.00, size = 0, normalized size = 0.00 \[ \text {Timed out} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(tan(d*(a+b*log(c*x^n)))/x,x, algorithm="giac")

[Out]

Timed out

________________________________________________________________________________________

maple [A]  time = 0.00, size = 30, normalized size = 1.15 \[ \frac {\ln \left (1+\tan ^{2}\left (d \left (a +b \ln \left (c \,x^{n}\right )\right )\right )\right )}{2 n b d} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

int(tan(d*(a+b*ln(c*x^n)))/x,x)

[Out]

1/2/n/b/d*ln(1+tan(d*(a+b*ln(c*x^n)))^2)

________________________________________________________________________________________

maxima [A]  time = 0.32, size = 24, normalized size = 0.92 \[ \frac {\log \left (\sec \left ({\left (b \log \left (c x^{n}\right ) + a\right )} d\right )\right )}{b d n} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(tan(d*(a+b*log(c*x^n)))/x,x, algorithm="maxima")

[Out]

log(sec((b*log(c*x^n) + a)*d))/(b*d*n)

________________________________________________________________________________________

mupad [B]  time = 3.78, size = 38, normalized size = 1.46 \[ \ln \relax (x)\,1{}\mathrm {i}-\frac {\ln \left ({\mathrm {e}}^{a\,d\,2{}\mathrm {i}}\,{\left (c\,x^n\right )}^{b\,d\,2{}\mathrm {i}}+1\right )}{b\,d\,n} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

int(tan(d*(a + b*log(c*x^n)))/x,x)

[Out]

log(x)*1i - log(exp(a*d*2i)*(c*x^n)^(b*d*2i) + 1)/(b*d*n)

________________________________________________________________________________________

sympy [A]  time = 4.13, size = 44, normalized size = 1.69 \[ \begin {cases} \log {\relax (x )} \tan {\left (a d \right )} & \text {for}\: b = 0 \\0 & \text {for}\: d = 0 \\\log {\relax (x )} \tan {\left (a d + b d \log {\relax (c )} \right )} & \text {for}\: n = 0 \\- \frac {\log {\left (\cos {\left (a d + b d \log {\left (c x^{n} \right )} \right )} \right )}}{b d n} & \text {otherwise} \end {cases} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(tan(d*(a+b*ln(c*x**n)))/x,x)

[Out]

Piecewise((log(x)*tan(a*d), Eq(b, 0)), (0, Eq(d, 0)), (log(x)*tan(a*d + b*d*log(c)), Eq(n, 0)), (-log(cos(a*d
+ b*d*log(c*x**n)))/(b*d*n), True))

________________________________________________________________________________________